package cn.yougou.serviceImpl;

import cn.yougou.dto.Query;
import cn.yougou.mapper.YgAddressMapper;
import cn.yougou.pojo.YgAddress;
import cn.yougou.service.admin.YgAdminAddressService;
import com.alibaba.dubbo.config.annotation.Service;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

@Service
public class YgAdminAddressServiceImpl implements YgAdminAddressService {

    @Autowired
    private YgAddressMapper ygAddressMapper;

    /**
     * 查询数据条数
     *
     * @param query
     * @return
     */
    @Override
    public int selNum(Query query) {
        return ygAddressMapper.selNum(query);
    }

    /**
     * 查询全部商品(分页)
     *
     * @param query
     * @return
     */
    @Override
    public List<YgAddress> seleAll(Query query) {
        return ygAddressMapper.seleAll(query);
    }
}
